package com.qf.pojo;

import lombok.Data;

@Data
public class Result {
    private boolean flag;
    private String msg;
    private Object data;

    public static Result success(String msg,Object data){
        Result result = new Result();
        result.setFlag(true);
        result.setMsg(msg);
        result.setData(data);
        return  result;
    }
    public static Result error(String msg){
        Result result = new Result();
        result.setFlag(false);
        result.setMsg(msg);

        return result;
    }
}
